using GameKitUnity.Core;
using UnityEngine;
using Object = UnityEngine.Object;

namespace OneGame.Gameplay
{
    public static class MonsterFactory
    {
        public static void Create(object target, System.Action<GameObject> callback)
        {
            AssetLoader.Instance.Load<GameObject>(target, "Monster-Orc", prefab =>
            {
                var gameObject = Object.Instantiate(prefab);
                callback?.Invoke(gameObject);
            });
        }
    }
}